1. Field of the Invention
The present invention relates to a photography apparatus, a photography method, and a photography program for obtaining an image of a subject by photography thereof.
2. Description of the Related Art
In order to reproduce a human face included in a photograph image in an ideal color, image processing has been carried out for correcting contrast of a face by extracting the face from an image.
For example, a method has been proposed in Japanese Unexamined Patent Publication No. 2000-188768 for correcting gradation. In this method, pixel values of an image are converted into pixel values in a YUV color space, and a skin-color region is detected in the image by assuming that pixels having values included in a skin-color space representing a predetermined skin-color in the YUV color space are skin-color pixels. A face region is then determined by using a characteristic quantity such as a mean luminance value of the skin-color region, and a state of exposure is judged based on skin-color information in the face region. In this manner, gradation is corrected.
Meanwhile, a digital camera obtains an image of desired quality by carrying out therein image processing such as gradation processing, color correction processing, density correction processing, and AWB on an image photographed by the camera. At the time of photography, AE processing is also carried out for carrying out photography in appropriate exposure. In the case where AE processing is carried out, an input through image, which is obtained before a shutter button is pressed, is divided into a plurality of regions, for example. Weighted mean luminance of the regions is then used as luminance of a subject. Alternatively, luminance of a subject is measured by intensively carrying out photometry in a center region of an image or by assuming that luminance at the point of focus is luminance of the subject. Based on a result of the measurement, an exposure value is determined for carrying out photography according to the exposure value.
If the method of face region detection described in Japanese Unexamined Patent Publication No. 2000-188768 is applied to AE processing by a digital camera, a farce region is detected in an input through image obtained before pressing of a shutter button, and an exposure value is determined based on the detected face region. Photography is then carried out according to the exposure value having been obtained. In this manner, exposure can be controlled appropriately according to a face region to be included in an image to be photographed.
However, the face region detection method described in Japanese Unexamined Patent Publication No. 2000-188768 cannot detect a skin-color region with accuracy in the case where a shadow is cast on a skin-color region or in the case where a boundary between a skin-color region and a background region thereof cannot be detected due to a color of the background region being close to a skin color, for example. In the former case, only a part without the shadow is detected as the skin-color region, and gradation is corrected based on a part with no shadow. As a result, contrast of an image having been subjected to the correction tends to be too sharp. Consequently, application of the method described in Japanese Unexamined Patent Publication No. 2000-188768 to a digital camera does not appropriately determine an exposure value.